Skip to main content

All Questions

8votes
2answers
528views

Fourier Series of a given function

This is a very simple code that expresses a function in terms of Trigonometric Fourier Series and generates a animation based on the harmonics. I would like to know some ways to improve the ...
Lipe's user avatar
4votes
0answers
993views

Slow copying of memmap array to numpy array

I have multiple binary (structured) file, each of 2GB, which I am currently reading in pair, using memmap to cross-correlate the same. I want to minimise the time required by this IO process, in the ...
Pavan Uttarkar's user avatar
5votes
1answer
336views

Implementing 3Blue1Brown's description of Fourier transform in Python+numpy

I have implemented the 3Blue1Brown's description of Fourier transform in Python+numpy for irregular and unsorted data, as described here. ...
Foad's user avatar
  • 369
9votes
1answer
4kviews

Bilinear image interpolation

I have written a bilinear interpolant, which is working moderately well except that is painfuly slow. How can rewrite the code to make it faster? Using opencv directly isn't a valid answer. ...
Lin's user avatar
  • 295
3votes
1answer
1kviews

Hurst Exponent calculator

I am aiming to compute the Hurst Exponent of a 1-D signal time series in Python. For now, I have one existing function hurst(sig) which returns the Hurst exponent ...
Matthew Anderson's user avatar
2votes
0answers
2kviews

Gray-level co-occurrence matrix feature computation

I have many images and want to compute the GLCM properties for every image. Below my code that runs many hours to complete the task: ...
Gilfoyle's user avatar
4votes
2answers
168views

Poor performance for signal processing

I have a program doing a LOT of iteration (thousands to millions to hundreds of millions). It's starting to take quite a lot of time (few minutes, to a few days), and despite all my effort to optimize ...
Mathieu's user avatar
4votes
0answers
5kviews

Applying hysteresis to a signal

Using python 3.6. I have written this code (below) to apply hysteresis to a signal (a numpy array). My aim was to create a function that didn't require any loop to remember the previous state of the ...
James Schinner's user avatar
4votes
2answers
225views

Temporal kernel filtering on video frames coming in a loop

I have a video which I read in a loop frame by frame. For every frame, I want to do temporal kernel filtering, the coefficients of which come from the input variable model (a dictionary). The temporal ...
GKS's user avatar
  • 159
2votes
1answer
1kviews

Find signal's maximum peak in window

I have a 9-dimensional signal (as a csv from this Gist) that looks like this: A signal peaks every 30 steps. I want to get the maximum values of the peaks in that ...
Seanny123's user avatar
2votes
1answer
2kviews

Generate a random discrete signal

I currently have this code to generate a discrete signal with random amplitudes, but a fixed frequency: ...
Seanny123's user avatar
9votes
4answers
17kviews

Recursively Save Python Dictionaries to HDF5 Files Using h5py

I have a bunch of custom classes for which I've implemented a method of saving files in HDF5 format using the h5py module. A bit of background: I've accomplished ...
stefco's user avatar
12votes
1answer
12kviews

Simple Phase Locked Loop

Here is a simple Phase Locked Loop, which is a circuit used in radio communications for synchronisation between transmitter and receiver. The loop works by calculating the (phase) difference between ...
Tom Kealy's user avatar
5votes
1answer
252views

Comparing FFTs to deduplicate IVR recordings

I've got a Python script that traverses two file trees, checking all .wav files for duplication. I'm still an undergrad, and have never worked with audio before. I'm not entirely sure this is going ...
Will's user avatar
  • 153
6votes
1answer
2kviews

Python implementation of multidimensional power spectral density with Welch method

I have done my best to write Welch method implementation for python for multidimensional time series and still in the case of one dimensional time series I am getting inconsistent response compared to ...
Naji's user avatar
  • 191

153050per page
close